package code;

import interfaces.*;

public class ProcessingCenter implements Machine{
	private String name;
	private Type type;
	private OrderImpl job;

	public ProcessingCenter(String name){
		this.name = name; type = Type.PROCESSING_CENTER;
	}
	
	public void startJob(OrderImpl o){
		this.job = o;
	}
	
	public void finishJob(){
		//TODO make broadcast, telling the job is done, or need to be parsed along to new queue
		job = null;
	}
	
	public String getName(){
		return name;
	}
	
	public Type getType(){
		return type;
	}
	
	public OrderImpl getJob(){
		return job;
	}
	
	public void setName(String name){
		this.name = name;
	}
}
